package common.peer;

import java.math.BigInteger;

import se.sics.kompics.Event;

public class JoinPeer extends Event {

	private final BigInteger peerId;
	private boolean source;
	private Integer bandwidth;

//-------------------------------------------------------------------
	public JoinPeer(BigInteger peerId) {
		this.peerId = peerId;
	}
	
//-------------------------------------------------------------------
	public JoinPeer(BigInteger peerId, boolean source, Integer bandwidth)
	{
		this.peerId = peerId;
		this.source = source;
		this.bandwidth = bandwidth;
	}

//-------------------------------------------------------------------
	public boolean isSource()
	{
		return this.source;
	}
//-------------------------------------------------------------------
	public Integer getBandwidth()
	{
		return this.bandwidth;
	}
//-------------------------------------------------------------------
	public BigInteger getPeerId() {
		return this.peerId;
	}
}
